﻿Imports BusinessRule.DTO
Imports Camstar.WebClient.WebServicesProxy.InSiteWebServices


Public Interface uMESCommonIBusiness

#Region "获取当前登录用户信息"
    Function GetCurrentUserInfo(ByVal strEmployeeName As String) As uMESProcessResult
#End Region
#Region "剔除工序名称中的零件图号"
    Function GetSpecNameWithoutProduct(ByVal strSpecName As String) As String
#End Region
#Region "根据ProductName获取默认版本"
    Function GetProductInfoByName(ByVal strProductName As String) As uMESProcessResult
#End Region

#Region "根据Product revision获取WorkFlow revision"
    Function GetWorkFlowByProduct(ByVal product As RevisionedObjectRef) As RevisionedObjectRef
#End Region
#Region "根据ID获取workflow信息"
    Function GetWorkflowInfoByID(ByVal strID As String) As uMESProcessResult
#End Region
#Region "根据WorkFlowName获取默认版本"
    Function GetWorkFlowInfoByName(ByVal strWorkFlowName As String) As uMESProcessResult
#End Region
#Region "生成新批次号"
    Function GetNewContainerName(ByVal strFactoryEName As String, ByVal strContainerName As String, ByVal intCount As Integer) As String
#End Region
#Region "生成新虚拟批次号"
    Function GetNewXNContainerName(ByVal strMfgOrderName As String, ByVal strFlag As String, ByVal intCount As Integer) As String
#End Region
#Region "生成新子批次号"
    Function GetNewMinorContainerName(ByVal strContainerName As String, ByVal intCount As Integer) As String
#End Region
#Region "获取批次当前工序之前的所有工序（包括当前工序）"
    Function GetPassedSpecList(ByVal strContainerName As String) As uMESProcessResult
#End Region
#Region "获取检验备注信息"
    Function GetCheckNotesInfo(ByVal strContainerName As String) As uMESProcessResult
#End Region

    Function GetNewContainerNameByJX(ByVal strPrefix As String) As String

    Function GetNewChildIndexByJX(ByVal strPrefix As String) As Integer

    Function GetLYCaseContainerName(ByVal pix As String, ByVal strContainerName As String) As String

    Function GetUerRole(ByVal strUserName As String, ByVal strRoleName As String) As DataTable

#Region "属性登记"
    Function SaveUserAttribute(ByVal para As ContainerStartInfo) As uMESProcessResult

    Function SetUserAttribute(ByVal para As ContainerStartInfo) As uMESProcessResult
#End Region

#Region "获取机型列表"
    Function GetProductFamily() As DataTable
#End Region

#Region "获取批次工序列表"
    Function GetSpecByContainerName(ByVal strContainerName As String) As uMESProcessResult
#End Region

#Region "获得工段人员"
    Function GetEmpByWorkCenter(ByVal strWorkCenter As String) As uMESProcessResult
#End Region
    Function GetEmplyeeList(ByVal strFullname As String, ByVal strFactoryName As String) As uMESProcessResult

    Function GetFactory() As DataTable

    Function GetWorkCenter(ByVal strFactoryID As String) As DataTable

    Function GetTeam(ByVal strWorkCenterName As String) As DataTable

    Function ReplaceContainerName(ByVal strContainerName As String) As String

#Region "得到工艺路线"
    Function GetWorkFlowSetp(ByVal strWorkflowName As String, ByVal strWorkFlowVersion As String) As DataTable
#End Region

#Region "获取关闭批次"
    Function GetCloseContainer(ByVal strContianerName As String) As DataTable
    ''' <summary>
    ''' 获取关闭批次 ‘add tianfw 2017-08-28
    ''' </summary>
    ''' <param name="para"></param>
    ''' <returns></returns>
    ''' <remarks></remarks>
    Function GetClostContaienr_new(ByVal para As Dictionary(Of String, String)) As uMESProcessResult
#End Region

#Region "得到角色和工序对应关系"
    Function GetSpecAndRoleInfo(ByVal strRoleList As String) As DataTable
#End Region

#Region "获取产品系列工艺路线BOM版本信息"
    Function GetProductByName(ByVal productname As String) As DataTable
#End Region

#Region "获取所选产品版本的工艺路线BOM"
    Function GetWorkflowBom(ByVal productname As String, ByVal revision As String) As DataTable
#End Region

#Region "获取工序名、号"
    Function GetWkFlStepname(ByVal workflowid As String) As DataTable
#End Region

#Region "获取配套表BOM"
    Function GetBOM(ByVal bomid As String) As DataTable
#End Region

#Region "获取检测项"
    Function GetCheckPointnote(ByVal workflowid As String) As DataTable
#End Region

#Region "获取所选产品版本的工艺路线信息"
    Function GetWorkflowBomByProduct(ByVal productname As String, ByVal revision As String) As DataTable
#End Region

#Region "获取所选产品版本的BOM信息"
    Function GetBomByProduct(ByVal productname As String, ByVal revision As String) As DataTable
#End Region

#Region "获取所选产品版本的材质信息"
    Function GetMaterialByProduct(ByVal productname As String, ByVal revision As String) As DataTable
#End Region

#Region "根据班组获取员工号信息"
    Function GetEmpByTeam(ByVal para As Dictionary(Of String, String)) As DataTable
#End Region


    ''' <summary>
    ''' 根据产品名称获取产品列表  add tianFW 2017/09/08
    ''' </summary>
    ''' <param name="strProductName"></param>
    ''' <returns></returns>
    ''' <remarks></remarks>
    Function GetProductInfoByName(ByVal strProductName As String, ByVal strProductRev As String) As System.Data.DataTable
    ''' <summary>
    ''' 根据产品ID获取工艺列表，包括子工艺，按车间过滤  add tianFW 2017/09/08
    ''' </summary>
    ''' <returns></returns>
    ''' <remarks></remarks>
    Function GetWorkFlowWithSubByProductID(ByVal strProductID As String, ByVal strFactoryID As String) As System.Data.DataTable
    ''' <summary>
    ''' 获取工艺路线所属工艺列表  add tianFW 2017/09/08
    ''' </summary>
    ''' <returns></returns>
    ''' <remarks></remarks>
    Function GetWorkFlowSetpsByWorkflowID(ByVal strWorkflowID As String) As System.Data.DataTable

    ''' <summary>
    ''' 流水卡扫描
    ''' create:Wangjh 2017-9-18
    ''' </summary>
    ''' <returns></returns>
    ''' <remarks></remarks>
    Function ContainerScan(ByVal containerID As String) As String

    ''' <summary>
    ''' 获取工艺路线所属工艺列表 create tianFW 2017/09/11
    ''' </summary>
    ''' <returns></returns>
    ''' <remarks></remarks>
    Function GetWorkFlowSetpsDetailByWorkflowID(ByVal para As Dictionary(Of String, String)) As System.Data.DataTable

    ''' <summary>
    ''' 获取工艺下面的bom信息ByworkflowID create tianFW 2017年12月4日
    ''' </summary>
    ''' <param name="workflowID"></param>
    ''' <returns></returns>
    ''' <remarks></remarks>
    Function GetBomByWorkflowID(ByVal workflowID As String) As DataTable

    ''' <summary>
    ''' 获取件号下面的bom信息ByProductID create tianFW 2017年12月5日
    ''' </summary>
    ''' <param name="ProductID"></param>
    ''' <returns></returns>
    ''' <remarks></remarks>
    Function GetBomByProductID(ByVal ProductID As String) As DataTable
End Interface
